import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/index'
import Application from '../views/Application'
import Directory from '../views/Directory'
import History from '../views/History'
import ApiList from '../components/ApiList/index'
import Interface01 from '../components/ApiList/Interface01/index'
import Interface02 from '../components/ApiList/Interface02/index'
import Interface03 from '../components/ApiList/Interface03/index'
import Interface04 from '../components/ApiList/Interface04/index'



Vue.use(VueRouter);

const routers = [
    {
        path:'/',
        name:"Home",
        component:Home,
        redirect: '/Directory',
        children:[
            {
                name:'Application',
                path: '/Application',
                component: Application
            },
            {
                name:'Directory',
                path: '/Directory',
                component: Directory
            },
            {
                name:'History',
                path: '/History',
                component: History
            },
            {
                name:'ApiList',
                path: '/ApiList',
                component: ApiList,
                redirect: '/Interface01',
                children: [
                    {
                        name:'Interface01',
                        path: '/Interface01',
                        component: Interface01
                    },
                    {
                        name:'Interface02',
                        path: '/Interface02',
                        component: Interface02
                    },
                    {
                        name:'Interface03',
                        path: '/Interface03',
                        component: Interface03
                    },
                    {
                        name:'Interface04',
                        path: '/Interface04',
                        component: Interface04
                    }
                ]
            },
        ]
    },
];

const router = new VueRouter({
    routes:routers
});


export default router
